package Utils;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;

public class ConBd {

public ConBd(){}

    public static Connection getConexionMysql() {
       Connection con = null;
        try {
   //String url = "jdbc:mysql://200.75.77.34:3306/videotienda";
        //  String url = "jdbc:mysql://172.17.202.182:3306/bd_tantra";
     String url = "jdbc:mysql://localhost/bdnuevohogar";
         // String url = "jdbc:mysql://localhost/historiasclinicas";
        //String usuario = //"videotienda";
       String NroDocumento = "root";
        //String clave = //"videotienda";
        String Nombre ="";
        Class.forName("com.mysql.jdbc.Driver");
        con = DriverManager.getConnection(url, NroDocumento, Nombre);
        System.out.println("Conexion a Base de Datos "+url+" . . . . .Ok");
        } catch (Exception e) {
            e.printStackTrace();

          System.out.print (e.getCause ());
         } finally { return con;}  }


//   public static void main( String args[] )
//       	{
//         ConBd.getConexionMysql ();
//        }
}